#ifndef _WIN32
#include <fnmatch.h>
#endif
#include <xp/bas/string.h>
#include <xp/bas/stdio.h>

int xp_main ()
{
#ifndef _WIN32
	if (fnmatch ("/*.bin*/LS", "/.bin/ls", FNM_PATHNAME | FNM_CASEFOLD) == 0) {
		xp_printf (XP_TEXT("fnmatch match\n"));
	}
#endif

	if (xp_strfnmat (XP_TEXT("/.bin/ls"), XP_TEXT("/*.bin*/LS"), XP_STRFNMAT_PATHNAME | XP_STRFNMAT_CASEFOLD)) {
		xp_printf (XP_TEXT("xp_strfnmat match\n"));
	}

	return 0;
}
